<!DOCTYPE html>
<html lang="zh-CN">

	<head>
		<meta name="viewport" content="initial-scale=1, maximum-scale=3, minimum-scale=1, user-scalable=no">
		<meta name="referrer" content="always">
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<title></title>
		<style type="text/css">
			<!-- body,
			div {
				margin: 0px;
				padding: 0px;
			}
			
			-->
		</style>
	</head>

	<body>
		<div style="width: 100%; margin: 0px auto;">
			<video id="videoElement" width="512" height="288" controls="controls"></video>
		</div>
		<script src="js/flv/flv.min.js"></script>
		<script type="text/javascript">
			var BomQuery = function(n) {
				var m = window.location.search.match(new RegExp("(\\?|&)" + n + "=([^&]*)(&|$)"));
				return !m ? "" : decodeURIComponent(m[2]);
			};

			(function() {
				if(flvjs.isSupported()) {
					console.info("成功", BomQuery("url"));

					var videoElement = document.getElementById('videoElement');
					var flvPlayer = flvjs.createPlayer({
						type: 'flv',
						url: BomQuery("url") ,
						isLive: true,
						cors: true
					}, {
						enableWorker: true,
						enableStashBuffer: false,
						stashInitialSize: 256,
					});
					flvPlayer.attachMediaElement(videoElement);
					flvPlayer.load();
					flvPlayer.play();
				} else {
					console.info("失败");
				}
			})();
		</script>
	</body>

</html>